<div id="<? echo $type?>_list" class="list" style="float: left">
<h3>Popular <? echo ucwords($type)?>s</h3>

<style>

#tag_artists_list div
{
    text-align:center;
    float: left;
    margin: 3px;
    width: 64;
    background-color: #eeeeee;
    border-radius: 3px;
    -mox-border-radius: 3px;
}
#tag_artists_list small
{
    font-size: 11px;
    color: #33333
}    
</style>
<?php

switch ($type)
{
    case 'tag':

    $font_size = 20;
    
    foreach ($data as $i => $tag)
    {
        echo '<span><a href="/post/tag/'.$tag['Tag']['tag'].'">'.ucwords($tag['Tag']['tag']).'</a></span>';
    }
    
    break;
    
    case 'tag_artists':

    $font_size = 20;

    foreach ($data['Artist'] as $i => $tag)
    {
        echo '<div><img src="/img/artist/'.$tag['Photo'][0]['id'].'.jpg" style="width: 60px" /><br/><small><a href="/post/artist/'.$tag['name'].'">'.ucwords($tag['name']).'</a></small></div>';
    }
    
    break;
}
?>
</div>